/*
 Navicat Premium Data Transfer

 Source Server         : localhost-qa
 Source Server Type    : MySQL
 Source Server Version : 50736
 Source Host           : localhost:13306
 Source Schema         : gin-vue-blog

 Target Server Type    : MySQL
 Target Server Version : 50736
 File Encoding         : 65001

 Date: 29/04/2025 10:06:22
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for adverts
-- ----------------------------
DROP TABLE IF EXISTS `adverts`;
CREATE TABLE `adverts` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `title` varchar(32) DEFAULT NULL,
  `href` longtext,
  `images` longtext,
  `is_show` tinyint(1) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of adverts
-- ----------------------------
BEGIN;
INSERT INTO `adverts` VALUES (1, 1735282763, 0, '0', '', '', 0, 0, 2);
INSERT INTO `adverts` VALUES (2, 1735283249, 0, 'title', 'href', 'images', 1, 0, 2);
INSERT INTO `adverts` VALUES (3, 1735283479, 0, 'title2', 'href', 'images', 1, 0, 1);
COMMIT;

-- ----------------------------
-- Table structure for article_tag
-- ----------------------------
DROP TABLE IF EXISTS `article_tag`;
CREATE TABLE `article_tag` (
  `tag_id` bigint(20) unsigned NOT NULL,
  `article_id` bigint(20) unsigned NOT NULL,
  PRIMARY KEY (`tag_id`,`article_id`),
  KEY `fk_article_tag_article` (`article_id`),
  CONSTRAINT `fk_article_tag_article` FOREIGN KEY (`article_id`) REFERENCES `articles` (`id`),
  CONSTRAINT `fk_article_tag_tag` FOREIGN KEY (`tag_id`) REFERENCES `tags` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of article_tag
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for articles
-- ----------------------------
DROP TABLE IF EXISTS `articles`;
CREATE TABLE `articles` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `title` varchar(32) DEFAULT NULL,
  `abstract` longtext,
  `content` longtext,
  `look_count` bigint(20) DEFAULT NULL,
  `commentcount` bigint(20) DEFAULT NULL,
  `digg_count` bigint(20) DEFAULT NULL,
  `collects_count` bigint(20) DEFAULT NULL,
  `user_id` bigint(20) unsigned DEFAULT NULL,
  `category` varchar(20) DEFAULT NULL,
  `source` longtext,
  `link` longtext,
  `banner_id` bigint(20) unsigned DEFAULT NULL,
  `nick_name` varchar(42) DEFAULT NULL,
  `banner_path` longtext,
  `tags` varchar(64) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`),
  KEY `fk_users_article_models` (`user_id`),
  KEY `fk_articles_banner` (`banner_id`),
  CONSTRAINT `fk_articles_banner` FOREIGN KEY (`banner_id`) REFERENCES `banners` (`id`),
  CONSTRAINT `fk_users_article_models` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of articles
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for auth2_collects
-- ----------------------------
DROP TABLE IF EXISTS `auth2_collects`;
CREATE TABLE `auth2_collects` (
  `user_id` bigint(20) unsigned NOT NULL,
  `article_id` bigint(20) unsigned NOT NULL,
  PRIMARY KEY (`user_id`,`article_id`),
  KEY `fk_auth2_collects_article` (`article_id`),
  CONSTRAINT `fk_auth2_collects_article` FOREIGN KEY (`article_id`) REFERENCES `articles` (`id`),
  CONSTRAINT `fk_auth2_collects_users` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of auth2_collects
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for banners
-- ----------------------------
DROP TABLE IF EXISTS `banners`;
CREATE TABLE `banners` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `status` int(11) NOT NULL DEFAULT '1',
  `update_date` bigint(20) DEFAULT NULL,
  `path` varchar(256) DEFAULT NULL,
  `hash` longtext,
  `name` varchar(255) DEFAULT NULL,
  `type` tinyint(4) DEFAULT '1',
  `deleted_at` bigint(20) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=24 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of banners
-- ----------------------------
BEGIN;
INSERT INTO `banners` VALUES (1, 1735093132, 1, 0, 'uploads/file', '1cc0af2e891229f4e5f4fe055d3a5af1', '0007.jpeg', 1, NULL);
INSERT INTO `banners` VALUES (2, 1735093132, 1, 0, 'uploads/file', '8a4e9d93f59c1f0695f36e2d1b28fa2b', '修改', 1, NULL);
INSERT INTO `banners` VALUES (3, 1735093132, 1, 0, 'uploads/file', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 1, NULL);
INSERT INTO `banners` VALUES (4, 1735191187, 1, 0, 'uploads/file', 'a708005cf77c72298921aa01981bd088', '0006.jpg', 1, 0);
INSERT INTO `banners` VALUES (5, 1735194827, 1, 0, 'uploads/file', '0e9551c60285cc5649e32393b2f3a452', '0003.jpeg', 1, 0);
INSERT INTO `banners` VALUES (6, 1735264608, 1, 0, 'up-z0.qiniup.comgvb/20241227095648_0004.jpg.pnd', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (7, 1735264697, 1, 0, 'up-z0.qiniup.comgvb/20241227095817_0004.jpg.pnd', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (8, 1735264980, 1, 0, 'up-z0.qiniup.com/gvb/20241227100259_0004.jpg.pnd', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (9, 1735265017, 1, 0, 'up-z0.qiniup.com/gvb/20241227100336_0004.jpg', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (10, 1735265148, 1, 0, 'up-z0.qiniup.comgvb/20241227100548_0004.jpg', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (11, 1735265252, 1, 0, 'up-z0.qiniup.com/gvb/20241227100732_0004.jpg', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (12, 1735265296, 1, 0, 'up-z0.qiniup.com/gvb/20241227100815_0004.jpg', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (13, 1735265955, 1, 0, 'up-z0.qiniup.com/gvb/20241227101915_0004.jpg', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (14, 1735270412, 1, 0, 'up-z0.qiniup.com/gvb/20241227113332_0004.jpg', '8b2162be6965e1865c139b32b25e7643', '0004.jpg', 2, 0);
INSERT INTO `banners` VALUES (15, 1735270455, 1, 0, 'uploads/file/tcp生命周期.png', '18aefc36e419222365a139a5f7c930b3', 'tcp生命周期.png', 1, 0);
INSERT INTO `banners` VALUES (16, 1741075760, 1, 0, 'uploads/file/nnw8rvfVP5xFad77634ed67bdd133e095e7ef23b36dc.jpg', '56eef340facfb044231be1d16ea7a1c9', 'nnw8rvfVP5xFad77634ed67bdd133e095e7ef23b36dc.jpg', 1, 0);
INSERT INTO `banners` VALUES (17, 1741075913, 1, 0, 'up-z0.qiniup.com/gvb/20250304161153_1LqzXrPuRO7L0940b25360363721ea7ca1f019110bfb.jpg', 'd5b5c7669f7be66bdb62fe55f4f3d06c', '1LqzXrPuRO7L0940b25360363721ea7ca1f019110bfb.jpg', 2, 0);
INSERT INTO `banners` VALUES (18, 1741076031, 1, 0, 'uploads/file/Rfw5DO2fYce051165b79d66dc5d49deb5bdb89b24f21.jpg', '6f944446ec4bf9c56a978792c4ae8022', 'Rfw5DO2fYce051165b79d66dc5d49deb5bdb89b24f21.jpg', 1, 0);
INSERT INTO `banners` VALUES (19, 1741076078, 1, 0, 'uploads/file/CwQ31EEQzN4Bc7b0b68923b4ab2029928e1525d0382f.jpg', 'e2e8d906a0bda98a8bef09b00821618a', 'CwQ31EEQzN4Bc7b0b68923b4ab2029928e1525d0382f.jpg', 1, 0);
INSERT INTO `banners` VALUES (20, 1741076133, 1, 0, 'uploads/file/MZ6Ir9XgWguTdefc1722b3e967bce511743cd36b3bdb.jpg', '39c4083fe0ebbb7cd220f1470e4e9d03', 'MZ6Ir9XgWguTdefc1722b3e967bce511743cd36b3bdb.jpg', 1, 0);
INSERT INTO `banners` VALUES (21, 1741076241, 1, 0, 'uploads/file/fPlNktH3tEIH0d1f2312dc3cba7bf8d123889b444caa.jpg', '28234cfe1c260438d945da281d1ab233', 'fPlNktH3tEIH0d1f2312dc3cba7bf8d123889b444caa.jpg', 1, 0);
INSERT INTO `banners` VALUES (22, 1741076386, 1, 0, 'uploads/file/HT9b5KsV12u3074e7f2f8582dd688afac8e2e2675d61.jpg', '18d49c0d29adcd3f230e591e8f2a43e8', 'HT9b5KsV12u3074e7f2f8582dd688afac8e2e2675d61.jpg', 1, 0);
INSERT INTO `banners` VALUES (23, 1741076443, 1, 0, 'uploads/file/ptv6MTwkYwpo7bd3e60a1c7a7a0b1aac20f9e18cbd91.jpg', 'aa304b465c9f489f594b9284e9f6d767', 'ptv6MTwkYwpo7bd3e60a1c7a7a0b1aac20f9e18cbd91.jpg', 1, 0);
COMMIT;

-- ----------------------------
-- Table structure for comments
-- ----------------------------
DROP TABLE IF EXISTS `comments`;
CREATE TABLE `comments` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `parent_comment_id` bigint(20) unsigned DEFAULT NULL,
  `content` varchar(256) DEFAULT NULL,
  `diggcount` tinyint(4) DEFAULT '0',
  `comment_count` tinyint(4) DEFAULT NULL,
  `article_id` bigint(20) unsigned DEFAULT NULL,
  `user_id` bigint(20) unsigned DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`),
  KEY `fk_comments_sub_comments` (`parent_comment_id`),
  KEY `fk_comments_user` (`user_id`),
  KEY `fk_articles_coument_models` (`article_id`),
  CONSTRAINT `fk_articles_coument_models` FOREIGN KEY (`article_id`) REFERENCES `articles` (`id`),
  CONSTRAINT `fk_comments_sub_comments` FOREIGN KEY (`parent_comment_id`) REFERENCES `comments` (`id`),
  CONSTRAINT `fk_comments_user` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of comments
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for departments
-- ----------------------------
DROP TABLE IF EXISTS `departments`;
CREATE TABLE `departments` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `name` varchar(30) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of departments
-- ----------------------------
BEGIN;
INSERT INTO `departments` VALUES (1, 1735868362, 1735868362, '技术部', 0, 1);
INSERT INTO `departments` VALUES (2, 1739165773057, 1735868362, '客户部', 0, 1);
INSERT INTO `departments` VALUES (3, 1736993392, 0, '运营部', 0, 1);
INSERT INTO `departments` VALUES (4, 1738339200, 1735868362, '人事部', 0, 1);
COMMIT;

-- ----------------------------
-- Table structure for face_backs
-- ----------------------------
DROP TABLE IF EXISTS `face_backs`;
CREATE TABLE `face_backs` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `content` varchar(128) DEFAULT NULL,
  `email` varchar(64) DEFAULT NULL,
  `apply_content` varchar(128) DEFAULT NULL,
  `is_apply` tinyint(1) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of face_backs
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for logs
-- ----------------------------
DROP TABLE IF EXISTS `logs`;
CREATE TABLE `logs` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `user_id` bigint(20) unsigned DEFAULT NULL,
  `ip` varchar(20) DEFAULT NULL,
  `nick_name` varchar(42) DEFAULT NULL,
  `token` varchar(256) DEFAULT NULL,
  `device` varchar(256) DEFAULT NULL,
  `addr` varchar(64) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`),
  KEY `fk_logs_user_model` (`user_id`),
  CONSTRAINT `fk_logs_user_model` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of logs
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for menu_banners
-- ----------------------------
DROP TABLE IF EXISTS `menu_banners`;
CREATE TABLE `menu_banners` (
  `menu_id` bigint(20) unsigned DEFAULT NULL,
  `banner_id` bigint(20) unsigned DEFAULT NULL,
  `sort` smallint(6) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  KEY `fk_menu_banners_menu` (`menu_id`),
  KEY `fk_menu_banners_banner` (`banner_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of menu_banners
-- ----------------------------
BEGIN;
INSERT INTO `menu_banners` VALUES (1, 1, 1, 0, 1);
INSERT INTO `menu_banners` VALUES (1, 2, 2, 0, 1);
INSERT INTO `menu_banners` VALUES (2, 3, 3, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 4, 4, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 1, 10, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 2, 20, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 1, 10, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 2, 20, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 1, 10, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 2, 20, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 1, 10, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 2, 20, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 1, 10, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 2, 20, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 1, 10, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 2, 20, 1735787287, 0);
INSERT INTO `menu_banners` VALUES (2, 1, 10, 0, 1);
INSERT INTO `menu_banners` VALUES (2, 2, 20, 0, 1);
INSERT INTO `menu_banners` VALUES (0, 1, 10, 0, 1);
INSERT INTO `menu_banners` VALUES (0, 2, 20, 0, 1);
INSERT INTO `menu_banners` VALUES (5, 1, 10, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 2, 20, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 1, 10, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 2, 20, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 1, 10, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 2, 20, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 1, 10, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 2, 20, 1735789594, 0);
INSERT INTO `menu_banners` VALUES (5, 1, 10, 0, 1);
INSERT INTO `menu_banners` VALUES (5, 2, 20, 0, 1);
INSERT INTO `menu_banners` VALUES (6, 1, 10, 0, 1);
INSERT INTO `menu_banners` VALUES (6, 2, 20, 0, 1);
INSERT INTO `menu_banners` VALUES (7, 1, 10, 0, 1);
INSERT INTO `menu_banners` VALUES (7, 2, 20, 0, 1);
INSERT INTO `menu_banners` VALUES (8, 1, 10, 1735790422, 0);
INSERT INTO `menu_banners` VALUES (8, 2, 20, 1735790422, 0);
INSERT INTO `menu_banners` VALUES (9, 1, 10, 0, 1);
INSERT INTO `menu_banners` VALUES (9, 2, 20, 0, 1);
INSERT INTO `menu_banners` VALUES (8, 1, 10, 0, 1);
INSERT INTO `menu_banners` VALUES (8, 2, 20, 0, 1);
COMMIT;

-- ----------------------------
-- Table structure for menus
-- ----------------------------
DROP TABLE IF EXISTS `menus`;
CREATE TABLE `menus` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `menu_title` varchar(30) DEFAULT NULL,
  `path` varchar(255) DEFAULT NULL,
  `slogan` varchar(64) DEFAULT NULL,
  `abstract` longtext,
  `abstract_time` bigint(20) DEFAULT NULL,
  `banner_time` bigint(20) DEFAULT NULL,
  `sort` smallint(6) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of menus
-- ----------------------------
BEGIN;
INSERT INTO `menus` VALUES (1, 1735541037, 0, '标题', NULL, 'slogan', '这是一堆描述\n这又是一个描述', 10, 20, 10, 0, 1);
INSERT INTO `menus` VALUES (2, 1735787287, 0, '标题', NULL, 'slogan更新', '这是一堆描述-更新\n这又是一个描述-更新', 10, 20, 10, 0, 1);
INSERT INTO `menus` VALUES (4, 1735789265, 0, '标题', '', 'slogan add', '这是一堆描述-add\n这又是一个描述-add', 10, 20, 10, 0, 1);
INSERT INTO `menus` VALUES (5, 1735789594, 0, '标题', '', 'slogan add', '这是一堆描述-ad222222d\n这又是一个描述-add', 10, 20, 10, 0, 1);
INSERT INTO `menus` VALUES (6, 1735789601, 0, '标题', '', 'slogan add', '这是一堆描述-ad222222d\n这又是一个描述-add', 10, 20, 10, 0, 1);
INSERT INTO `menus` VALUES (7, 1735789991, 0, '标题', '', 'slogan add', '这是一堆描述-ad222222d\n这又是一个描述-add', 10, 20, 10, 0, 1);
INSERT INTO `menus` VALUES (8, 1735790422, 0, '标题', '', 'slogan add', '这是一堆描述-ad222222d\n这又是一个描述-add', 10, 20, 10, 0, 1);
INSERT INTO `menus` VALUES (9, 1735790414, 0, '标题', '', 'slogan add', '这是一堆描述-ad222222d\n这又是一个描述-add', 10, 20, 10, 0, 1);
COMMIT;

-- ----------------------------
-- Table structure for messages
-- ----------------------------
DROP TABLE IF EXISTS `messages`;
CREATE TABLE `messages` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `send_user_id` bigint(20) unsigned NOT NULL,
  `send_user_nick_name` varchar(42) DEFAULT NULL,
  `send_user_avatar` longtext,
  `rev_user_id` bigint(20) unsigned NOT NULL,
  `rev_user_nick_name` varchar(42) DEFAULT NULL,
  `rev_user_avatar` longtext,
  `is_read` tinyint(1) DEFAULT '0',
  `content` longtext,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`,`send_user_id`,`rev_user_id`) USING BTREE,
  KEY `fk_messages_send_user_model` (`send_user_id`),
  KEY `fk_messages_rev_user_model` (`rev_user_id`),
  CONSTRAINT `fk_messages_rev_user_model` FOREIGN KEY (`rev_user_id`) REFERENCES `users` (`id`),
  CONSTRAINT `fk_messages_send_user_model` FOREIGN KEY (`send_user_id`) REFERENCES `users` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of messages
-- ----------------------------
BEGIN;
INSERT INTO `messages` VALUES (1, 1736478598, 0, 1, '用户昵称-1', 'avatar', 2, '用户昵称-12', 'avatar', 0, '随便发一条消息！', 0, 1);
INSERT INTO `messages` VALUES (2, 1736478668, 0, 2, '用户昵称-12', 'avatar', 1, '用户昵称-1', 'avatar', 0, '有啥事', 0, 1);
INSERT INTO `messages` VALUES (3, 1736478789, 0, 1, '用户昵称-1', 'avatar', 2, '用户昵称-12', 'avatar', 0, '没事 看你在忙啥呢', 0, 1);
INSERT INTO `messages` VALUES (4, 1736478831, 0, 2, '用户昵称-12', 'avatar', 1, '用户昵称-1', 'avatar', 0, '嘻嘻嘻', 0, 1);
COMMIT;

-- ----------------------------
-- Table structure for roles
-- ----------------------------
DROP TABLE IF EXISTS `roles`;
CREATE TABLE `roles` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `name` varchar(30) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of roles
-- ----------------------------
BEGIN;
INSERT INTO `roles` VALUES (1, 1735868362, 1735868362, '超级管理员', 0, 1);
INSERT INTO `roles` VALUES (2, 1739165773057, 1735868362, '管理员', 0, 1);
INSERT INTO `roles` VALUES (3, 1736993392, 0, '客户经理', 0, 1);
INSERT INTO `roles` VALUES (4, 1738339200, 1735868362, '客服', 0, 1);
COMMIT;

-- ----------------------------
-- Table structure for tags
-- ----------------------------
DROP TABLE IF EXISTS `tags`;
CREATE TABLE `tags` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `title` varchar(32) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of tags
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for user2_collects
-- ----------------------------
DROP TABLE IF EXISTS `user2_collects`;
CREATE TABLE `user2_collects` (
  `user_id` bigint(20) unsigned NOT NULL,
  `article_id` bigint(20) unsigned NOT NULL,
  `created_at` bigint(20) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`user_id`,`article_id`),
  KEY `fk_user2_collects_article_model` (`article_id`),
  CONSTRAINT `fk_user2_collects_article_model` FOREIGN KEY (`article_id`) REFERENCES `articles` (`id`),
  CONSTRAINT `fk_user2_collects_user_model` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of user2_collects
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for user_img
-- ----------------------------
DROP TABLE IF EXISTS `user_img`;
CREATE TABLE `user_img` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `user_id` bigint(20) unsigned NOT NULL,
  `name` varchar(200) NOT NULL,
  `url` varchar(200) DEFAULT NULL,
  `created_at` bigint(20) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`) USING BTREE,
  KEY `fk_user2_collects_article_model` (`name`)
) ENGINE=InnoDB AUTO_INCREMENT=20 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of user_img
-- ----------------------------
BEGIN;
INSERT INTO `user_img` VALUES (1, 15, 'food.jpeg', 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (2, 19, 'food.jpeg', 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (3, 19, 'food.jpeg', 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (4, 19, 'food.jpeg', 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (5, 19, 'food.jpeg', 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (6, 23, '/FhKNv1-yBVAIg6ALYag9RjbWBRq4', '/FhKNv1-yBVAIg6ALYag9RjbWBRq4', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (7, 24, '/FhKNv1-yBVAIg6ALYag9RjbWBRq4', '/FhKNv1-yBVAIg6ALYag9RjbWBRq4', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (8, 25, 'https://upload.qiniup.com/FjxGPLWTbwDWdPlNpkJqVU_iHDcx', 'https://upload.qiniup.com/FjxGPLWTbwDWdPlNpkJqVU_iHDcx', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (9, 26, 'https://upload.qiniup.com/FlnA5J447Xg7r8j6FN9SFhBVsAHG', 'https://upload.qiniup.com/FlnA5J447Xg7r8j6FN9SFhBVsAHG', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (10, 27, '0007.jpeg/FlnA5J447Xg7r8j6FN9SFhBVsAHG', '/FlnA5J447Xg7r8j6FN9SFhBVsAHG', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (11, 28, '0007.jpeg/FhKNv1-yBVAIg6ALYag9RjbWBRq4', '/FhKNv1-yBVAIg6ALYag9RjbWBRq4', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (12, 29, '1739438072416/FjS7sPzXBr4JZdd8P5y9xOXgyTRq', '/FjS7sPzXBr4JZdd8P5y9xOXgyTRq', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (13, 29, '1739438072450/FnkGQBChNaHyW__kRGHNopkmgPdo', '/FnkGQBChNaHyW__kRGHNopkmgPdo', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (14, 29, '1739438072474/FlnA5J447Xg7r8j6FN9SFhBVsAHG', '/FlnA5J447Xg7r8j6FN9SFhBVsAHG', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (15, 29, '1739438072665/FhKNv1-yBVAIg6ALYag9RjbWBRq4', '/FhKNv1-yBVAIg6ALYag9RjbWBRq4', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (16, 30, '1739438755951/FjS7sPzXBr4JZdd8P5y9xOXgyTRq', '/FjS7sPzXBr4JZdd8P5y9xOXgyTRq', NULL, 1739439766, 0);
INSERT INTO `user_img` VALUES (17, 30, '1739438756016/FlnA5J447Xg7r8j6FN9SFhBVsAHG', '/FlnA5J447Xg7r8j6FN9SFhBVsAHG', NULL, 1739439766, 0);
INSERT INTO `user_img` VALUES (18, 30, '1739438755951/FjS7sPzXBr4JZdd8P5y9xOXgyTRq', '/FjS7sPzXBr4JZdd8P5y9xOXgyTRq', NULL, NULL, 1);
INSERT INTO `user_img` VALUES (19, 30, '1739438756016/FlnA5J447Xg7r8j6FN9SFhBVsAHG', '/FlnA5J447Xg7r8j6FN9SFhBVsAHG', NULL, NULL, 1);
COMMIT;

-- ----------------------------
-- Table structure for users
-- ----------------------------
DROP TABLE IF EXISTS `users`;
CREATE TABLE `users` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `create_date` bigint(20) DEFAULT NULL,
  `update_date` bigint(20) DEFAULT NULL,
  `nick_name` varchar(255) DEFAULT NULL,
  `user_name` varchar(255) DEFAULT NULL,
  `password` varchar(64) DEFAULT NULL,
  `avatar` varchar(256) DEFAULT NULL,
  `email` varchar(128) DEFAULT NULL,
  `tel` varchar(18) DEFAULT NULL,
  `addr` varchar(64) DEFAULT NULL,
  `token` varchar(64) DEFAULT NULL,
  `ip` varchar(20) DEFAULT NULL,
  `depart_id` tinyint(4) DEFAULT NULL,
  `role` tinyint(4) DEFAULT '1',
  `sign_source` smallint(6) DEFAULT NULL,
  `deleted_at` bigint(20) DEFAULT NULL,
  `status` bigint(20) DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=45 DEFAULT CHARSET=utf8mb4;

-- ----------------------------
-- Records of users
-- ----------------------------
BEGIN;
INSERT INTO `users` VALUES (1, 1735868362, 1735868362, '用户昵称-1234569', '用户名-1-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 1739177008, 0);
INSERT INTO `users` VALUES (2, 1739165773057, 1735868362, '用户昵称-12', '用户名-12-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '456@qq.ccom', '456789', '456789', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (3, 1736993392, 0, '用户名n2', '用户名n2', '$2a$04$Hps4neG.X8xwEAYLiRptn.XoTzOQyYsUk0d8U2INAiP3iFLzC9H1W', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (4, 1738339200, 1735868362, '用户昵称-状态0', '用户名-1-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 0, 0);
INSERT INTO `users` VALUES (5, 1738339200, 1735868362, '用户昵称-12', '用户名-12-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '456@qq.ccom', '456789', '456789', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (6, 1738339200, 0, '用户名n2', '用户名n2', '$2a$04$Hps4neG.X8xwEAYLiRptn.XoTzOQyYsUk0d8U2INAiP3iFLzC9H1W', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (7, 1738339200, 1735868362, '用户昵称-1', '用户名-1-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (8, 1738339200, 1735868362, '用户昵称-12', '用户名-12-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '456@qq.ccom', '456789', '456789', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (9, 1738339200, 0, '用户名n2', '用户名n2', '$2a$04$Hps4neG.X8xwEAYLiRptn.XoTzOQyYsUk0d8U2INAiP3iFLzC9H1W', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (10, 1735868362, 1735868362, '用户昵称-1', '用户名-1-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (11, 1735868362, 1735868362, '用户昵称-12', '用户名-12-edit', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', '', '456@qq.ccom', '456789', '456789', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (12, 1736993392, 0, '用户名n2', '用户名n2', '$2a$04$Hps4neG.X8xwEAYLiRptn.XoTzOQyYsUk0d8U2INAiP3iFLzC9H1W', '', '123@qq.ccom', '123123', '123123', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (19, 1739338869, 0, 'nick_name', 'user_name', '$2a$04$E2VmQGubAwyLJw731HMzre56X0u6PqEPQBmAx5.6ygOvF1DxKvqcm', '', 'email', '13922222222', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (23, 1739433190, 0, '户晓', '户晓', '$2a$04$5KOBO/Eb8yEs07ZfsromF.IZfBoXpHcebfkqpdj.Y7Cnv5BK55/Ty', '', '123@qq.com', '13666666662', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (24, 1739433382, 0, '甲鱼', '甲鱼', '$2a$04$pdfEXLhpXhvmbXCZ8elDQudCMpXrn1zMP.BI03FDwaVvsMYviM87K', '', '123@qq.com', '13666666663', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (25, 1739435016, 0, '欧阳修水', '欧阳修水', '$2a$04$GsZNmgArmyjpxpdHuYGqWuMEoh8s2amJGY7Fe.CraC2g79rMI2TMK', '', '123@qqq.com', '13811111111', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (26, 1739435065, 0, '欧阳明日', '欧阳明日', '$2a$04$0siVIDvOOtKMqBeRFDBW9eUiXfkLlO99/SCZdGM4nrfpAfWXADBxq', '', '123@qq.com', '13811111112', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (27, 1739436698, 0, '张晓', '张晓', '$2a$04$7guh4l0YRfp1nbdaoc7WYuW/ajQ5OSu86NgIV2r1yQGFUGL8UJ1Ye', '', '123@qq.com', '13266666666', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (28, 1739436790, 0, '红叶', '红叶', '$2a$04$KvR1S/mKaVAx64bxynNWcOkyP3cReryZxJH6LR.fonfXRE.bSxVg6', '', '123@qq.com', '13266666677', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (29, 1739438083, 0, '多图', '多图', '$2a$04$aJMTUcv/HBH/4S.oBJFXpeaATJjLDIyibC8Zcrs63noeUI1jHrozC', '', '123@qq.com', '13666666664', '', '', '', NULL, 1, 0, 0, 1);
INSERT INTO `users` VALUES (30, 1739439766, 1739439766, '纯多小', '纯多小', '$2a$04$N/42RyzpfHwpYByjAops7uFRssTLNOywBYayba/Walq8E27R3Jyx6', '', '123@qq.com', '13666666666', '', '', '', 2, 2, 0, 0, 1);
INSERT INTO `users` VALUES (32, 1741078117, 0, 'K4sYwy.jpg', 'K4sYwy.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/K4sYwyvkZU3X703e17e569a1c4127ddc8c62bdb9aeec.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (33, 1741081920, 0, '0XS6gl.jpg', '0XS6gl.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/0XS6gldXE2KG5e3031ada413bd9543599fcc5975fc56.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (34, 1741082092, 0, 'g1vrD2.jpg', 'g1vrD2.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/g1vrD2kbM2BEac4798d8a585a1bf6e2ae6b3914fb6b4.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (35, 1741082291, 0, 'fysORX.jpg', 'fysORX.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/fysORX7h9lhK68564811795f7f6ffe15d1511067bbc7.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (36, 1741082368, 0, '9bmiLC.jpg', '9bmiLC.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/9bmiLCdXE5xT89921419e314175291605285df9189d4.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (37, 1741082369, 0, 'ij97VG.jpg', 'ij97VG.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/ij97VGngV6aA2a8549c59da905ab3ab3acbcd5d541bc.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (38, 1741082370, 0, '6LcT8A.jpg', '6LcT8A.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/6LcT8AflkR5nfc56d275bac74cc6943725f3b082638d.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (39, 1741082371, 0, 'jpbFol.jpg', 'jpbFol.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/jpbFolQCQvB9cf75ab87c8667d091a0068fcb015b01e.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (40, 1741082390, 0, 'Jzgis7.jpg', 'Jzgis7.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/Jzgis7H5Wescc9741d37bef8e3bd67b93b2208969fac.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (41, 1741082400, 0, 'lV28Fa.jpg', 'lV28Fa.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/lV28FaIl1GJ0c4edf9b4e8af8b7587057ecaa7231f32.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (42, 1741082406, 0, 'De7oP7.jpg', 'De7oP7.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/De7oP73IXS2n09b0c50eb0f2fe2e2bd573f7f450a736.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (43, 1741082458, 0, 'kw9VMJ.jpg', 'kw9VMJ.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/kw9VMJQJT3Cpb5dc8a0955865b855b43933c66e3710e.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
INSERT INTO `users` VALUES (44, 1741082480, 0, 'beNq9T.jpg', 'beNq9T.jpg', '$2a$04$9aucV9.KidlaSN/LRaOzoePjIZkjTPpao5IRC4SaLu9cXI7IylF3a', 'uploads/file/beNq9TIYJ1Ja35eec24cb163d84885797177666b9961.jpg', '', '', '', '', '', 0, 0, 0, 0, 1);
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
